#define ElemType int

typedef struct ListNode List_Node;

#include "common.h"

bool searchMatrix(int** matrix, int matrixSize, int* matrixColSize, int target);

int main()
{
	return 0;
}

bool searchMatrix(int** matrix, int matrixSize, int* matrixColSize, int target)
{
	int col = *matrixColSize - 1, row = 0;
	while (row < matrixSize && col >= 0) {
		int off = matrix[row][col] - target;
		if (off == 0)
			return true;
		else if (off < 0)
			row++;
		else
			col--;
	}
	return false;
}
